<template>
	<view class="page" :style="{minHeight:$height()}">
		<view class="title">
			{{problem.title}}
		</view>
		<view class="item" style="margin-top: 93rpx;">
			<u-parse :html="problem.content"></u-parse>
		</view>
	</view>
</template>

<script>
	export default {
		data() {
			return {
				id: 0,
				problem:{}
			}
		},
		onLoad(options) {
			this.id = options.id
		},
		onShow() {
			this.getProblem()
		},
		methods: {
			getProblem() {
				this.$axios.request(`${this.$api.getProblem}/${this.id}`,"GET").then((val)=>{
					this.problem = val.data
					uni.setNavigationBarTitle({
						title:val.data.title
					})
				})
			}
		}
	}
</script>

<style>
	.page {
		width: 100%;
		padding: 0 0 68rpx;
		background-color: #FFFFFF;
		overflow: hidden;
	}

	.title {
		width: 90%;
		height: 56rpx;
		font-size: 40rpx;
		font-family: "PingFang SC";
		font-weight: 300;
		line-height: 56rpx;
		color: #666666;
		margin: 36rpx auto 0;
		
		
	}

	.item {
		width: 690rpx;
		margin: 48rpx auto 0;
		line-height: 50rpx;
	}

	.step {
		height: 33rpx;
		font-size: 24rpx;
		font-family: "PingFang SC";
		font-weight: 600;
		line-height: 33rpx;
		text-align: left;
		color: #666666;
		opacity: 1;
	}

	.info {
		height: 33rpx;
		font-size: 24rpx;
		font-family: "PingFang SC";
		font-weight: 500;
		line-height: 33rpx;
		color: #999999;
		margin-top: 11rpx;
		opacity: 1;
	}

	.iamgBox {
		display: flex;
		justify-content: space-between;
		align-items: center;
		width: 100%;
		height: 375rpx;
		margin-top: 14rpx;
	}

	.firstImage,
	.lastImage {
		width: 280rpx;
		height: 375rpx;
	}

	image {
		width: 100%;
		height: 100%;
	}

	.ail {
		width: 86rpx;
		height: 35rpx;
	}
</style>
